﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.Text;
using System.ServiceModel.Web;
using RESTServices.Dominio;
using System.Data.SqlClient;

namespace RESTServices
{
       [ServiceContract]
    public interface IReservas
    {
        [OperationContract]
        [WebInvoke(Method = "POST", UriTemplate = "Reservas", ResponseFormat = WebMessageFormat.Json)]
        Reserva CrearReserva(Reserva reservaCrear);

        [OperationContract]
        [WebInvoke(Method = "GET", UriTemplate = "Reservas/{idreserva}", ResponseFormat = WebMessageFormat.Json)]
        Reserva ObtenerReserva(string idreserva);

        [OperationContract]
        [WebInvoke(Method = "PUT", UriTemplate = "Reservas", ResponseFormat = WebMessageFormat.Json)]
        Reserva ModificarReserva(Reserva reservaModificar);

        [OperationContract]
        [WebInvoke(Method = "DELETE", UriTemplate = "Reservas/{idreserva}", ResponseFormat = WebMessageFormat.Json)]
        void EliminarReserva(string idreserva);

        [OperationContract]
        [WebInvoke(Method = "GET", UriTemplate = "Reservas/", ResponseFormat = WebMessageFormat.Json)]
        List<Reserva> ListarReservas();
    }
}
